<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>${message("企业信息编辑")}</title>
<link href="/resources/css/common.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="/resources/js/reference/jquery.js"></script>
<script type="text/javascript" src="/resources/js/reference/jquery.validate.js"></script>
<script type="text/javascript" src="/resources/js/base/dialog.js"></script>
<script type="text/javascript" src="/resources/js/base/request.js"></script>
<script type="text/javascript" src="/resources/js/base/global.js"></script>
<script type="text/javascript" src="/resources/js/base/file.js"></script>
<link href="/resources/css/mmGrid.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="/resources/js/reference/mmGrid.js"></script>
<script type="text/javascript">
function editPrice(t,e){
	extractNumber(t,0,false,e)
}

function editQty(t,e){
	extractNumber(t,0,false,e)
}
$().ready(function() {
	var $inputForm = $("#inputForm");
	$("input[name='start_img']").single_upload({
		uploadSize:"medium"
	});
	$("input[name='logo']").single_upload({
		uploadSize:"medium"
	});
	// 表单验证
	$inputForm.validate({
		rules: {
			name: "required",
			partnerModel:"required",
			simple_name:{required: true},
			checkModel:"required",
			company_name: {required: true},
			company_code: {required: true},
			activateCode: {required:true,min: 0, number:true,digits:true},
			maxAmount: {min: 0, number:true,digits:true},
			timeOut: {min: 0, max: 100, number:true,digits:true}
		},
		submitHandler:function(form){
			return false;
		}
	});
	$("form").bindAttribute({
		isConfirm:true,
	    callback: function(resultMsg){
	        $.message_timer(resultMsg.type,resultMsg.content,1000,function(){
				location.reload(true);
			});
	    }
	 });
	 
});
</script>
</head>
<body>
	<div class="pathh">
		&nbsp;${message("查看企业信息")}
	</div>
	<form id="inputForm" action="update.jhtml" method="post" type="ajax" validate-type="validate">
		<input type="hidden" name="id" value="${company_info.id}" />
		<input type="hidden" name="create_by" value="${company_info.create_by}" />
		<input type="hidden" name="appFirstTimePageUrl" value="${company_info.appFirstTimePageUrl}"/>
		<input type="hidden" name="isEnabledCountry" value="false" />
		<input type="hidden" name="webSite" value="${company_info.webSite}" />
		<div class="tabContent">
			<table class="input input-edit">
			<tr>
				<th>
					<span class="requiredField">*</span>${message("企业全称")}:
				</th>
				<td>
					<input type="text" name="company_name"  value="${company_info.company_name}" class="text" maxlength="200"  btn-fun="clear" />
				</td>
				<th>
					<span class="requiredField">*</span>${message("11051")}:
				</th>
				<td>
					<input type="text" name="simple_name" value="${company_info.simple_name}" class="text" maxlength="200"  btn-fun="clear" />
				</td>
				<th>
					[#if adminCompany??][#else]<span class="requiredField">*</span>[/#if]${message("11052")}:
				</th>
				<td>
					[#if adminCompany??]
						${company_info.company_code}
						<input type="hidden" name="company_code" class="text"  value="${company_info.company_code}" maxlength="200" />
					[#else]
						<input type="text" name="company_code"  value="${company_info.company_code}" class="text" maxlength="200"  btn-fun="clear" readOnly/>
					[/#if]
				</td>
				<th>
					<span class="requiredField">*</span>${message("11070")}:
				</th>
				<td>
					<div class="nums-input ov">
						<input type="button" class="b decrease" value="-"  onMouseDown ="decrease(this,event)">
						<input type="text"  class="t"  name="activateCode" value="${company_info.activateCode}" minData="0" oninput="editQty (this,event)" onpropertychange="editQty(this,event)" >
						<input type="button" value="+" class="b increase"  onMouseDown ="increase(this,event)">
					</div>					
				</td>
			</tr>
			<tr>
				<th>
					<span class="requiredField"></span>${message("是否启用")}:
				</th>
				<td>
					<label>
						<input type="checkbox" name="isEnabled" value="true" [#if company_info.isEnabled] checked="checked"[/#if]/>${message("启用")}
						<input type="hidden" name="_isEnabled" value="false"/>
					</label>
				</td>
				<th>
					<span class="requiredField"></span>${message("企业唯一标识")}:
				</th>
				<td colspan="5">
					${company_info.uniqueIdentify}
					<input type="hidden" name="uniqueIdentify"  value="${company_info.uniqueIdentify}" maxlength="200" readonly/>&emsp;&emsp;&emsp;
				</td>
				
			</tr>
			<!-- <tr>
				<th>
					${message("企业logo")}:
				</th>
				<td colspan="5">
					<input type="hidden" name="logo" value="${company_info.logo}"/>
				</td>
			</tr> -->
			<tr>
				<th>
					<span class="requiredField"></span>${message("11062")}:
				</th>
				<td colspan="7" >
					<textarea name="note" class="text" maxlength="500">${company_info.note}</textarea>
				</td>
			</tr>
		</table>
		</div>
		<div class="fixed-top">
			<input type="submit" id="submit_button" class="button sureButton" value="${message("1013")}" />
			<input type="button" onclick="location.reload(true);" class="button refreshButton ml15" value="${message("刷新")}">
		</div>
	</form>
</body>
</html>